package utils;

import java.util.Random;

public class CustomRandom {

	private static CustomRandom instance;
	private static Random random;
	
	public static  CustomRandom getInstance(){
		int seed = 7;
		if( instance == null){
			instance = new CustomRandom(seed);
		}
		return instance;
	}
	public CustomRandom(int seed){
		this.random = new Random(seed);
		
	}
	
	public double getDoubleRandom(){
		return random.nextDouble();
	}
	
	public static int getRandomInt(int topValue){
//		System.out.println(random);
		return random.nextInt(topValue);
		
	}
}
